package cn.xpg.controller;

import java.util.List;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import cn.xpg.entity.Test;
import cn.xpg.service.TestService;

@Controller
public class TestController {

	@Resource
	private TestService testService;
	
	@RequestMapping("getTestList.do")
	public String getTestList(HttpServletRequest request){
		String name = request.getParameter("name");
		List<Test> testList=testService.getTestList(name);
		request.setAttribute("testList", testList);
		return "test";
	}
	
}
